<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>200410</title>
</head>
<body>
    <script>
        (function () {
            var a = (b = 5)
        })();

        console.log(b)   //5
        console.log(a)     //Error: is not defined
    </script>
</body>
</html>